 <?php 
define('IN_WONDERSHARE', true);
require( '../../inc/config.inc.php');
require( '../../includes/cls_mysql.php');
$db = new cls_mysql($db_host, $db_user, $db_pass, $db_name);

if( $_GET['code'] != md5('get_daniusoft_info') ) exit('error code!');
function get_cbs_info($db)
{
	$data = array();
    $where_str = empty($_GET['web_type'])?'':' AND web_type = '.trim(htmlspecialchars($_GET['web_type']));
	if(!empty($_GET['cbsid']))
	{
		$sql = 'SELECT cbsid ,discount_price,original_price ,product_name FROM cbs_product_info 
		WHERE  FIND_IN_SET(cbsid,"'.$_GET['cbsid'].'") '.$where_str.'  ORDER BY FIND_IN_SET( cbsid,  "'.$_GET['cbsid'].'" )  ';
		$result = $db->query($sql);
		while($row = $db->fetch_array($result))
		{
			$data[] = $row;
		}
	}
	echo  serialize($data);

}
$fun = $_GET['fun'];
$fun( $db );